'use strict';

const conn = require('../../libs/Conn');

module.exports = async function (params) {
    let querySql = ``;
    if(params.type === '0'){
        querySql = ` SELECT
                        '全部' AS dataType,
                        '0' AS value
                    
                    UNION SELECT user_name AS dataType,user_id AS value FROM user_file WHERE delete_sign = 1 AND group_id != 1 `
    }else{
        querySql = ` SELECT user_name AS dataType,user_id AS value FROM user_file WHERE delete_sign = 1 AND group_id != 1 `;
    }
    let rec = await conn(querySql);
    return {success: true, data: rec};

};